package com.yuanfeng.base.controller;

import com.yuanfeng.commoms.util.ResponseResult;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;
/**
 * @ClassName SmsInfoController
 * @Description SMS配置信息
 * @Author cyp
 * @Date 2023/5/19 18:04
 * @Version 1.0
 */
@RestController
@RequestMapping("base/sms")
public class SmsInfoController extends BaseController {


    /**
     * 初始化SMS配置信息 服务间feign 调用使用
     *
     * @param
     * @return
     */
    @PostMapping("/feign/oss/selectSMSInfo")
    public ResponseResult selectSMSInfoFeign() {
        ResponseResult result = null;
        try {
            result = selectSMSInfo.selectSMSInfoFeign();
        } catch (Exception e) {
            return ResponseResult.fail(e.getMessage());
        }
        return result;
    }
    /**
     * 初始化SMS配置信息 加密返回
     *
     * @param
     * @return
     */
    @PostMapping(value = "/goods/oss/selectSMSInfoEncryption")
    public ResponseResult selectSMSInfoEncryption() {
        ResponseResult result = null;
        try {
            result = selectSMSInfo.selectSMSInfoEncryption();

        } catch (Exception e) {
            return ResponseResult.fail(e.getMessage());
        }

        return result;
    }
}
